package com.ruoyi.admin.domain;

import java.util.List;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 家属信息对象 family
 * 
 * @author ruoyi
 * @date 2023-01-10
 */
public class Family extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 家属表主键id */
    private Long id;

    /** 家属关系 */
    @Excel(name = "家属关系")
    private Long relation;

    /** 家属姓名 */
    @Excel(name = "家属姓名")
    private String name;

    /** 家属性别 */
    @Excel(name = "家属性别")
    private Long sex;

    /** 家属出生日期 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "家属出生日期", width = 30, dateFormat = "yyyy-MM-dd")
    private Date birthday;

    /** 家属手机号 */
    @Excel(name = "家属手机号")
    private String phone;

    /** 查询关联家属信息 */
    private List<TPatientFamily> tPatientFamilyList;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setRelation(Long relation) 
    {
        this.relation = relation;
    }

    public Long getRelation() 
    {
        return relation;
    }
    public void setName(String name) 
    {
        this.name = name;
    }

    public String getName() 
    {
        return name;
    }
    public void setSex(Long sex) 
    {
        this.sex = sex;
    }

    public Long getSex() 
    {
        return sex;
    }
    public void setBirthday(Date birthday) 
    {
        this.birthday = birthday;
    }

    public Date getBirthday() 
    {
        return birthday;
    }
    public void setPhone(String phone) 
    {
        this.phone = phone;
    }

    public String getPhone() 
    {
        return phone;
    }

    public List<TPatientFamily> getTPatientFamilyList()
    {
        return tPatientFamilyList;
    }

    public void setTPatientFamilyList(List<TPatientFamily> tPatientFamilyList)
    {
        this.tPatientFamilyList = tPatientFamilyList;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("relation", getRelation())
            .append("name", getName())
            .append("sex", getSex())
            .append("birthday", getBirthday())
            .append("phone", getPhone())
            .append("createTime", getCreateTime())
            .append("tPatientFamilyList", getTPatientFamilyList())
            .toString();
    }
}
